#define _CRT_SECURE_NO_WARNINGS 1
#include "heap.h"

void test1()
{
	int a[] = { 4,2,8,1,5,6,9,7,33,678,43,36,89};
	HP hp;
	HeapInit(&hp);
	for (int i = 0; i < sizeof(a) / sizeof(HPDataType); i++)
	{
		HeapPush(&hp, a[i]);
	
	}

	int k = 0;
	scanf("%d", &k);

	while (k--)
	{
		printf("%d ", HPTop(&hp));
		HeapPop(&hp);
	}
	printf("\n");

}
int main()
{
	test1();
	return 0;
}